<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title></title>
	</head>
	<body>
		<script type="text/javascript">
			function sort(arr) {
				var t;
				for (var i = 0; i < arr.length; i++) { //比较的轮数
					for (var j = 0; j < arr.length - i - 1; j++) { //每一轮比较的次数，次数随轮数增加而减少，因为每一轮都能确定一个最大数
						if (arr[j] > arr[j + 1]) {
							t = arr[j + 1];
							arr[j + 1] = arr[j];
							arr[j] = t;
						}
					}
				}
			}

			function list() {
				for (var x = 0; x < arr.length; x++) {
					console.log(arr[x]);
				}
			}

			var arr2 = [7, 5, 12, 3, 30];
			// sort(arr2);
			// list(arr2);

			var arr3 = [70, 50, 120, 30, 300];
			// sort(arr3);
			// list(arr3);

			var arr1 = [1, 2];
			var arr2 = [3, 4];
			var arr3 = new Array();
			arr3[0] = arr1;
			arr3[1] = arr2;
			
			var arr4 = arr3[0];
			console.log(arr4[0]);
		</script>
	</body>
</html>
